package org.westboy.common.base;
import com.google.common.collect.Lists;
import javafx.beans.property.ListProperty;
import javafx.beans.property.SimpleListProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.StringProperty;
import javafx.collections.FXCollections;
import javafx.collections.ObservableList;
import org.springframework.stereotype.Component;
import org.westboy.model.Order;
import org.westboy.model.OrderPro;

import javax.annotation.PostConstruct;
import java.util.List;

/**
 * Description:
 *
 * @author Jin
 * @create 2018-01-04
 **/
@Component
public class OrderContext {

    private  Order order;

    private ListProperty<OrderPro> listProperty;


    @PostConstruct
    private void init(){
        this.listProperty  = new SimpleListProperty<>();
        this.order = new Order();
    }

    public Order getOrder() {
        return order;
    }

    public void setList(ObservableList<OrderPro> observableList){
        listProperty.setValue(observableList);
    }

    public ListProperty<OrderPro> listPropertyProperty() {
        return listProperty;
    }
}
